import http from './request'

const companyManage = {
  // 公司列表数据查询
  getCompanyList(params = {}) {
    return http.post(`/sysCompany/getCompanyList`, params)
  },
  // 添加公司
  addCompany(params = {}) {
    return http.post(`/sysCompany/addCompany`, params)
  },
  // id 查询公司
  selectCompanyById(params = {}) {
    return http.get(`/sysCompany/selectCompanyById`, { params })
  },
  // 编辑提交
  updateCompany(params = {}) {
    return http.post(`/sysCompany/updateCompany`, params)
  },
  // id 删除公司
  deleteCompany(params = {}) {
    return http.get(`/sysCompany/deleteCompany`, { params })
  },
  // 公司id 下的菜单树
  selectMenuTreeByConpany(params = {}) {
    return http.get(`/sysCompany/selectMenuTreeByConpany`, { params })
  },
  // 公司分配菜单
  saveRolePermission(params = {}) {
    console.log(params)
    return http.post(`/sysCompany/saveRolePermission`, params)
  },
}

export default companyManage
